package com.bluestarenergy.provisioning.engine.service;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Isolation;
import org.springframework.transaction.annotation.Propagation;
import org.springframework.transaction.annotation.Transactional;

import com.bluestarenergy.provisioning.engine.dao.BudgetBillingDAO;
import com.bluestarenergy.provisioning.engine.domain.AccountProductBudgetBilling;
import com.bluestarenergy.provisioning.engine.domain.CustomerCredit;

@Service("budgetBillingService")
public class BudgetBillingServiceImpl implements BudgetBillingService{

	@Autowired
	private BudgetBillingDAO budgetBillingDAO;
	
	@Transactional(propagation=Propagation.REQUIRED,isolation=Isolation.READ_COMMITTED,readOnly=false)
	public List<AccountProductBudgetBilling> findAccountProductBudgetBillingAll() {
		return budgetBillingDAO.findAccountProductBudgetBillingAll();
	}

	public List<CustomerCredit> readCustomer() {
		return budgetBillingDAO.readCustomer();
	}
	
	

	public void writeCustomer(CustomerCredit customerCredit) {
		budgetBillingDAO.writeCustomer(customerCredit);
	}

}
